3.74 \(\int \frac{(a+b \log (c x^n)) \log (d (e+f x)^m)}{x} \, dx\)

Optimal. Leaf size=100 \[ -m \text{PolyLog}\left (2,-\frac{f x}{e}\right ) \left (a+b \log \left (c x^n\right )\right )+b m n \text{PolyLog}\left (3,-\frac{f x}{e}\right )+\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (d (e+f x)^m\right )}{2 b n}-\frac{m \log \left (\frac{f x}{e}+1\right ) \left (a+b \log \left (c x^n\right )\right )^2}{2 b n} \]

[Out]

((a + b*Log[c*x^n])^2*Log[d*(e + f*x)^m])/(2*b*n) - (m*(a + b*Log[c*x^n])^2*Log[1 + (f*x)/e])/(2*b*n) - m*(a +
 b*Log[c*x^n])*PolyLog[2, -((f*x)/e)] + b*m*n*PolyLog[3, -((f*x)/e)]

________________________________________________________________________________________

Rubi [A]  time = 0.0927204, antiderivative size = 100, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 4, integrand size = 24, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.167, Rules used = {2375, 2317, 2374, 6589} \[ -m \text{PolyLog}\left (2,-\frac{f x}{e}\right ) \left (a+b \log \left (c x^n\right )\right )+b m n \text{PolyLog}\left (3,-\frac{f x}{e}\right )+\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (d (e+f x)^m\right )}{2 b n}-\frac{m \log \left (\frac{f x}{e}+1\right ) \left (a+b \log \left (c x^n\right )\right )^2}{2 b n} \]

Antiderivative was successfully verified.

[In]

Int[((a + b*Log[c*x^n])*Log[d*(e + f*x)^m])/x,x]

[Out]

((a + b*Log[c*x^n])^2*Log[d*(e + f*x)^m])/(2*b*n) - (m*(a + b*Log[c*x^n])^2*Log[1 + (f*x)/e])/(2*b*n) - m*(a +
 b*Log[c*x^n])*PolyLog[2, -((f*x)/e)] + b*m*n*PolyLog[3, -((f*x)/e)]

Rule 2375

Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))^(r_.)]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.))/(x_), x_Symbol] :
> Simp[(Log[d*(e + f*x^m)^r]*(a + b*Log[c*x^n])^(p + 1))/(b*n*(p + 1)), x] - Dist[(f*m*r)/(b*n*(p + 1)), Int[(
x^(m - 1)*(a + b*Log[c*x^n])^(p + 1))/(e + f*x^m), x], x] /; FreeQ[{a, b, c, d, e, f, r, m, n}, x] && IGtQ[p,
0] && NeQ[d*e, 1]

Rule 2317

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)/((d_) + (e_.)*(x_)), x_Symbol] :> Simp[(Log[1 + (e*x)/d]*(a +
b*Log[c*x^n])^p)/e, x] - Dist[(b*n*p)/e, Int[(Log[1 + (e*x)/d]*(a + b*Log[c*x^n])^(p - 1))/x, x], x] /; FreeQ[
{a, b, c, d, e, n}, x] && IGtQ[p, 0]

Rule 2374

Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.))/(x_), x_Symbol] :> -Sim
p[(PolyLog[2, -(d*f*x^m)]*(a + b*Log[c*x^n])^p)/m, x] + Dist[(b*n*p)/m, Int[(PolyLog[2, -(d*f*x^m)]*(a + b*Log
[c*x^n])^(p - 1))/x, x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IGtQ[p, 0] && EqQ[d*e, 1]

Rule 6589

Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[PolyLog[n + 1, c*(a
+ b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[b*d, a*e]

Rubi steps

\begin{align*} \int \frac{\left (a+b \log \left (c x^n\right )\right ) \log \left (d (e+f x)^m\right )}{x} \, dx &=\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (d (e+f x)^m\right )}{2 b n}-\frac{(f m) \int \frac{\left (a+b \log \left (c x^n\right )\right )^2}{e+f x} \, dx}{2 b n}\\ &=\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (d (e+f x)^m\right )}{2 b n}-\frac{m \left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{f x}{e}\right )}{2 b n}+m \int \frac{\left (a+b \log \left (c x^n\right )\right ) \log \left (1+\frac{f x}{e}\right )}{x} \, dx\\ &=\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (d (e+f x)^m\right )}{2 b n}-\frac{m \left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{f x}{e}\right )}{2 b n}-m \left (a+b \log \left (c x^n\right )\right ) \text{Li}_2\left (-\frac{f x}{e}\right )+(b m n) \int \frac{\text{Li}_2\left (-\frac{f x}{e}\right )}{x} \, dx\\ &=\frac{\left (a+b \log \left (c x^n\right )\right )^2 \log \left (d (e+f x)^m\right )}{2 b n}-\frac{m \left (a+b \log \left (c x^n\right )\right )^2 \log \left (1+\frac{f x}{e}\right )}{2 b n}-m \left (a+b \log \left (c x^n\right )\right ) \text{Li}_2\left (-\frac{f x}{e}\right )+b m n \text{Li}_3\left (-\frac{f x}{e}\right )\\ \end{align*}

Mathematica [A]  time = 0.0660259, size = 147, normalized size = 1.47 \[ a m \text{PolyLog}\left (2,\frac{f x}{e}+1\right )-b m \log \left (c x^n\right ) \text{PolyLog}\left (2,-\frac{f x}{e}\right )+b m n \text{PolyLog}\left (3,-\frac{f x}{e}\right )+a \log \left (-\frac{f x}{e}\right ) \log \left (d (e+f x)^m\right )+b \log (x) \log \left (c x^n\right ) \log \left (d (e+f x)^m\right )-b m \log (x) \log \left (c x^n\right ) \log \left (\frac{f x}{e}+1\right )-\frac{1}{2} b n \log ^2(x) \log \left (d (e+f x)^m\right )+\frac{1}{2} b m n \log ^2(x) \log \left (\frac{f x}{e}+1\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[((a + b*Log[c*x^n])*Log[d*(e + f*x)^m])/x,x]

[Out]

-(b*n*Log[x]^2*Log[d*(e + f*x)^m])/2 + a*Log[-((f*x)/e)]*Log[d*(e + f*x)^m] + b*Log[x]*Log[c*x^n]*Log[d*(e + f
*x)^m] + (b*m*n*Log[x]^2*Log[1 + (f*x)/e])/2 - b*m*Log[x]*Log[c*x^n]*Log[1 + (f*x)/e] - b*m*Log[c*x^n]*PolyLog
[2, -((f*x)/e)] + a*m*PolyLog[2, 1 + (f*x)/e] + b*m*n*PolyLog[3, -((f*x)/e)]

________________________________________________________________________________________

Maple [C]  time = 0.16, size = 1795, normalized size = 18. \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*ln(c*x^n))*ln(d*(f*x+e)^m)/x,x)

[Out]

-m*dilog((f*x+e)/e)*a+ln(d)*a*ln(x)-1/2*I*Pi*csgn(I*d*(f*x+e)^m)^3*b*ln(c)*ln(x)-1/4*I*Pi*csgn(I*d*(f*x+e)^m)^
3*b/n*ln(x^n)^2-1/2*I*ln(d)*b*Pi*csgn(I*c*x^n)^3*ln(x)+1/4*Pi^2*csgn(I*d*(f*x+e)^m)^3*b*csgn(I*c)*csgn(I*c*x^n
)^2*ln(x)+1/4*Pi^2*csgn(I*d*(f*x+e)^m)^3*b*csgn(I*x^n)*csgn(I*c*x^n)^2*ln(x)+1/4*Pi^2*csgn(I*d)*csgn(I*d*(f*x+
e)^m)^2*b*csgn(I*c*x^n)^3*ln(x)+1/2*I*m*dilog((f*x+e)/e)*b*Pi*csgn(I*c*x^n)^3+1/2*I*Pi*csgn(I*d)*csgn(I*d*(f*x
+e)^m)^2*a*ln(x)+1/2*I*Pi*csgn(I*(f*x+e)^m)*csgn(I*d*(f*x+e)^m)^2*a*ln(x)+1/4*Pi^2*csgn(I*(f*x+e)^m)*csgn(I*d*
(f*x+e)^m)^2*b*csgn(I*c*x^n)^3*ln(x)+(b*ln(x)*ln(x^n)-1/2*b*n*ln(x)^2-1/2*I*ln(x)*Pi*b*csgn(I*c)*csgn(I*x^n)*c
sgn(I*c*x^n)+1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x+e)/e)*b*ln(x^n)+1/2*ln(d)*b/n*ln(x^n)^2-m*ln(x)*ln((f*x+e)/e)*a-m*dilog((f*x+
e)/e)*b*ln(c)+ln(d)*b*ln(c)*ln(x)+m*ln(x)^2*ln((f*x+e)/e)*b*n+1/2*I*m*ln(x)*ln((f*x+e)/e)*b*Pi*csgn(I*c)*csgn(
I*x^n)*csgn(I*c*x^n)-1/4*Pi^2*csgn(I*d)*csgn(I*(f*x+e)^m)*csgn(I*d*(f*x+e)^m)*b*csgn(I*c)*csgn(I*x^n)*csgn(I*c
*x^n)*ln(x)-1/2*m*b*n*ln(x)^2*ln(1+f*x/e)+m*dilog((f*x+e)/e)*b*n*ln(x)-m*b*n*ln(x)*polylog(2,-f*x/e)-m*ln(x)*l
n((f*x+e)/e)*b*ln(c)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} -\frac{1}{2} \,{\left (b n \log \left (x\right )^{2} - 2 \, b \log \left (x\right ) \log \left (x^{n}\right ) - 2 \,{\left (b \log \left (c\right ) + a\right )} \log \left (x\right )\right )} \log \left ({\left (f x + e\right )}^{m}\right ) - \int -\frac{b f m n x \log \left (x\right )^{2} + 2 \, b e \log \left (c\right ) \log \left (d\right ) + 2 \, a e \log \left (d\right ) - 2 \,{\left (b f m \log \left (c\right ) + a f m\right )} x \log \left (x\right ) + 2 \,{\left (b f \log \left (c\right ) \log \left (d\right ) + a f \log \left (d\right )\right )} x - 2 \,{\left (b f m x \log \left (x\right ) - b f x \log \left (d\right ) - b e \log \left (d\right )\right )} \log \left (x^{n}\right )}{2 \,{\left (f x^{2} + e x\right )}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*x^n))*log(d*(f*x+e)^m)/x,x, algorithm="maxima")

[Out]

-1/2*(b*n*log(x)^2 - 2*b*log(x)*log(x^n) - 2*(b*log(c) + a)*log(x))*log((f*x + e)^m) - integrate(-1/2*(b*f*m*n
*x*log(x)^2 + 2*b*e*log(c)*log(d) + 2*a*e*log(d) - 2*(b*f*m*log(c) + a*f*m)*x*log(x) + 2*(b*f*log(c)*log(d) +
a*f*log(d))*x - 2*(b*f*m*x*log(x) - b*f*x*log(d) - b*e*log(d))*log(x^n))/(f*x^2 + e*x), x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{{\left (b \log \left (c x^{n}\right ) + a\right )} \log \left ({\left (f x + e\right )}^{m} d\right )}{x}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*x^n))*log(d*(f*x+e)^m)/x,x, algorithm="fricas")

[Out]

integral((b*log(c*x^n) + a)*log((f*x + e)^m*d)/x, x)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*ln(c*x**n))*ln(d*(f*x+e)**m)/x,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (b \log \left (c x^{n}\right ) + a\right )} \log \left ({\left (f x + e\right )}^{m} d\right )}{x}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*x^n))*log(d*(f*x+e)^m)/x,x, algorithm="giac")

[Out]

integrate((b*log(c*x^n) + a)*log((f*x + e)^m*d)/x, x)